-
Notifications
You must be signed in to change notification settings - Fork 203
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Prevent GCPManagedCluster reconciler to not crash if Network.Name and Network.Subnets is not passed to it #1284
base: main
Are you sure you want to change the base?
Conversation
…e and Network.Subnets is not passed to it
…usterHasNoNetworkDefined when reconciling Also introduces Container interface which implements bits of https://github.com/googleapis/google-cloud-go/blob/a187451a912835703078e5b6a339c514edebe5de/container/apiv1/cluster_manager_client.go#L468 since it's an internal interface.
Hi @tasdikrahman. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
✅ Deploy Preview for kubernetes-sigs-cluster-api-gcp ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Lint and Tests pass locally. |
/ok-to-test |
Hello @damdo @richardcase , I saw that the https://github.com/joelanford/go-apidiff diff test is failing above for the change introduced here https://github.com/kubernetes-sigs/cluster-api-provider-gcp/pull/1284/files#diff-e36fd81faa8d27206684360336226f7384431b104ff17c7d1dc677628a881e41R119 to an interface to ease testing as earlier it was pointing to a concrete type. Please let me know if you would like me to make any changes for it. The two places where this new interface is introduced is
|
Hello folks, whenever you get time to check the PR again for any changes you would like me to make, I will make the changes requested. Thanks for your time. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this @tasdikrahman .
For an non-GKE cluster, we allow not specifying the network. What this change does is effectively make Network required for GKE clusters even though its marked optional in the API: https://github.com/kubernetes-sigs/cluster-api-provider-gcp/blob/main/exp/api/v1beta1/gcpmanagedcluster_types.go#L44.
We need to be able to have a nil network as this will cause the "default" network to be used. Could you look at where we set the network (here) and instead of what we currently do check for a nil value before setting it? Like we do for ControlPlaneVersion
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: tasdikrahman The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@tasdikrahman: The following tests failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
What type of PR is this?
/kind bug
What this PR does / why we need it:
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #1187
Special notes for your reviewer:
Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.
TODOs:
Release note: